From: Kan-Ru Chen Date: Sat, 17 Dec 2011 10:41:52 +0000 (+0800) Subject: Enable hardening flags X-Git-Tag: archive/raspbian/1.1.9+ds1-4+rpi1^2^2~222 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=567a5d737f104023d8a2dd1ab20d13d65c9514d5;p=opencc.git Enable hardening flags --- diff --git a/debian/changelog b/debian/changelog index b7c8e99..bc88a0b 100644 --- a/debian/changelog +++ b/debian/changelog @@ -3,6 +3,7 @@ opencc (0.3.0-1) unstable; urgency=low * New upstream release * Remove autotools-dev and quilt from Build-Depends * Support `nostrip' DEB_BUILD_OPTIONS + * Enable hardening flags. * debian/patches/fix-big-endian-build.diff: merged upstream * debian/patches/fix-new-test-cases.patch: New patch. diff --git a/debian/control b/debian/control index a6d5394..57e3303 100644 --- a/debian/control +++ b/debian/control @@ -2,7 +2,7 @@ Source: opencc Priority: optional Maintainer: IME Packaging Team Uploaders: LI Daobing , Asias He -Build-Depends: debhelper (>= 7.0.50~), cmake +Build-Depends: debhelper (>= 7.0.50~), dpkg-dev (>= 1.16.1.1~), cmake Standards-Version: 3.9.2 Section: libs Homepage: http://code.google.com/p/opencc diff --git a/debian/rules b/debian/rules index c81f1fa..75ecb9a 100755 --- a/debian/rules +++ b/debian/rules @@ -1,13 +1,10 @@ #!/usr/bin/make -f - -ifeq (,$(filter nostrip,$(DEB_BUILD_OPTIONS))) - BUILD_TYPE=Release -else - BUILD_TYPE=Debug -endif +export DEB_BUILD_MAINT_OPTIONS = hardening=+all +DPKG_EXPORT_BUILDFLAGS = 1 +include /usr/share/dpkg/buildflags.mk %: dh $@ override_dh_auto_configure: - dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=$(BUILD_TYPE) -DENABLE_GETTEXT:BOOL=ON + dh_auto_configure -- -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_BUILD_TYPE=Release -DENABLE_GETTEXT:BOOL=ON